<com:TPanel id="PortletEditMode" Style="border-bottom: 1px solid black; margin: 0px 0px 0px 0px; text-align: right;">
	<com:TImageButton OnClick="MoveButtonClicked" ImageURL="<%=$this->Page->getTheme()->getBaseUrl()%>/images/edit/page_next.gif" Text="<%[Move to another area%>" />
	<com:TImageButton OnClick="UpButtonClicked" ImageURL="<%=$this->Page->getTheme()->getBaseUrl()%>/images/edit/page_up.gif" Text="<%[Move portlet up]%>" />
	<com:TImageButton OnClick="DownButtonClicked" ImageURL="<%=$this->Page->getTheme()->getBaseUrl()%>/images/edit/page_down.gif" Text="<%[Move portlet down%>" />
	<com:TImageButton OnClick="PropertyButtonClicked" ImageURL="<%=$this->Page->getTheme()->getBaseUrl()%>/images/edit/application_form.png" Text="<%[Properties]%>" />
	<com:TImageButton OnClick="DeleteButtonClicked" ImageURL="<%=$this->Page->getTheme()->getBaseUrl()%>/images/edit/application_delete.png" Text="<%[Remove portlet]%>" Attributes.onclick="if(!confirm('<%= Prado::localize('Are you sure?') %>')) return false;" />
</com:TPanel>
<com:TPanel Id="pnlMenuProperties" GroupingText="<%[Menu properties]%>" DefaultButton="btnSaveMenu">
	<table width="100%">
		<tr>
			<td colspan="2"><com:TValidationSummary Display="Dynamic" ValidationGroup="valMenuProp" /></td>
		</tr>

		<tr>
			<td><%[Menu title]%><br /><com:TTextBox Id="tbMenuTitle" Columns="20" /></td>
		</tr>
		<tr>
			<td>
				<%[Menu css]%><br /><com:TTextBox Id="tbMenuCss" Columns="20" />
				<com:TRegularExpressionValidator ControlToValidate="tbMenuCss" ValidationGroup="valMenuProp" Display="Dynamic" RegularExpression="^[a-zA-Z]+$" Text="*" ErrorMessage="<%[CSS cannot contain spaces]%>" ControlCssClass="input-error2" />
			</td>
		</tr>
		<tr>
			<td>
			<%[Active css]%><br /><com:TTextBox Id="tbActiveCss" Columns="20" />
			<com:TRegularExpressionValidator ControlToValidate="tbActiveCss" ValidationGroup="valMenuProp" Display="Dynamic" RegularExpression="^[a-zA-Z]+$" Text="*" ErrorMessage="<%[CSS cannot contain spaces]%>" ControlCssClass="input-error2" />
			</td>
		</tr>
		<tr>
			<td>
				<%[In active css]%><br /><com:TTextBox Id="tbInActiveCss" Columns="20" />
				<com:TRegularExpressionValidator ControlToValidate="tbInActiveCss" ValidationGroup="valMenuProp" Display="Dynamic" RegularExpression="^[a-zA-Z]+$" Text="*" ErrorMessage="<%[CSS cannot contain spaces]%>" ControlCssClass="input-error2" />
				</td>
		</tr>
		<tr>
			<td><com:TLinkButton Id="btnSaveMenu" Text="<%[Save]%>" CssClass="link-button" OnClick="SaveMenuProperties" ValidationGroup="valMenuProp" CausesValidation="true" /></td>
		</tr>
	</table>
</com:TPanel>
<com:TPanel Id="pnlMenuItems" GroupingText="<%[Menu items]%>">
	<com:TDataList
		Id="dlMenuItems"
		DataKeyField="pagename"
		OnDeleteCommand="deleteItem"
		onItemCommand="itemCommand"
		HeaderStyle.CssClass="grid-header"
		HeaderStyle.Width="100%"
		ItemStyle.CssClass="grid-row1"
		ItemStyle.Width="100%"
		AlternatingItemStyle.CssClass="grid-row2"
		EditItemStyle.CssClass="grid-row-edit"
		SelectedItemStyle.CssClass="grid-row-selected"
		EnableViewState="true"
		style="width: 100%;">
		<prop:HeaderTemplate>
			<table border="0" width="100%">
				<tr>
					<td><%[Page]%></td>
					<td><%[Active]%></td>
					<td><%[Order]%></td>
					<td><%[Cmd]%></td>
				</tr>
			</table>
		</prop:HeaderTemplate>
		<prop:ItemTemplate>
			<table border="0" width="100%">
				<tr>
					<td align="left" width="50%"><%# $this->DataItem['displayname'] %></td>
					<td><com:TLinkButton Text="<%[Up]%>" CommandName="MoveUpLM" CommandParameter=<%#$this->DataItem['pagename'] %> />&nbsp;<com:TLinkButton Text="<%[Dwn]%>" CommandName="MoveDownLM" CommandParameter=<%#$this->DataItem['pagename'] %>/></td>
					<td style="text-align: right;" width="15%">
						<com:TLinkButton Text="<%[Delete]%>" CommandName="delete" Attributes.onclick="if(!confirm('<%= Prado::localize('Are you sure?') %>')) return false;" />
					</td>
				</tr>
			</table>
		</prop:ItemTemplate>
	</com:TDataList>
</com:TPanel>
<com:TPanel Id="pnlAddMenuItem" GroupingText="<%[Add item]%>" DefaultButton="btnAddMenuItem">
	<table>
		<tr>
			<td><%[Page]%><br /><com:TDropDownList Id="ddlAddPages" DataTextField="displayname" DataValueField="name"/></td>
		</tr>
		<tr>
			<td><%[Display]%><br /><com:TTextBox Id="tbAddDisplayName" Columns="20" /></td>
		</tr>
		<tr>
			<td><com:TLinkButton Id="btnAddMenuItem" Text="<%[Add item]%>" CssClass="link-button" OnClick="AddMenuItem" /></td>
		</tr>
	</table>
</com:TPanel>
